<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>所有招聘的职位</title>
<link rel="stylesheet" href="<%= request.getContextPath()%>/vendor/bootstrap/css/bootstrap.min.css"> 
<style>

.search {
		display: inline;
		
	}
	#formc{
		width:400px;
		float:left;
		
	}
	#btnc{
		float:left;
		
	}
	#search-div{
		margin-left:30%;
	}
	.a{
		text-decoration: none;
	}
	a:link {text-decoration: none;color:red;}
	a:visited {color:green；text-decoration:none;}
	a:hover  {color:blue;text-decoration:underline;}
	a:active {color:orange;text-decoration:blink;}
	
</style>
</head>
<body>
<div class="container">

	<a href="<%=request.getContextPath() %>/static/talent/talent-login.jsp">求职者登录</a>
	<a href="<%=request.getContextPath() %>/static/talent/talent-register.jsp">求职者注册</a>
	|
	<a href="<%=request.getContextPath() %>/static/company/company-login.jsp">企业登录</a>
	<a href="<%=request.getContextPath() %>/static/company/company-register.jsp">企业注册</a>
	<hr>
	
	<form action="<%=request.getContextPath()%>/PositionListServlet" method="post">
	<div id = "search-div">
			<input type="text" name="positionName" class="form-control search" id = "formc">
			<input type="submit" value="职位搜索" class="btn btn-primary" id = "btnc"/><br>
			</div>
		</form>
		<hr>
		<c:forEach items = "${positionList}" var="position">
		${position.company$name}　"${position.company$slogan }"<br>
		<a href = "<%=request.getContextPath()%>/PositionServlet?command=detail&id=${position.id}">${position.name}</a>  ${position.salary1}-${position.salary2}　　　${position.company$address}　　　<fmt:formatDate value="${position.releaseTime }" pattern="yyyy-MM-dd HH:mm:ss"/>
		<hr/> 
		</c:forEach>
		
		
</div>

<script src="vendor/jquery.min.js"></script>
	<script src="vendor/layer/layer.js"></script>
	<script>

		/**
		 * 确认注销
		 */
		function confirmLogout(url) {
			layer.confirm('确认注销？', {
				btn : [ '确认', '取消' ]
			//按钮
			}, function() {
				location = url;
			}, function() {
			});
		}
	</script>
</body>
</html>